//
//  LzwBellTableViewCell.m
//  NewHalfsugar
//
//  Created by 刘志武 on 16/1/2.
//  Copyright © 2016年 刘志武. All rights reserved.
//

#import "LzwBellTableViewCell.h"
#import "LzwBaseImageView.h"
#import "LzwBaseLable.h"
#import "UIImageView+WebCache.h"

@interface LzwBellTableViewCell ()

@property (nonatomic, retain) LzwBaseLable *myBellLable;
@property (nonatomic, retain) LzwBaseImageView *myImageBell;
@property (nonatomic, retain) LzwBaseImageView *myImageBell1;

@end

@implementation LzwBellTableViewCell

-(void)dealloc{
    
    [_myBellLable release];
    [_myImageBell release];
    [_myImageBell1 release];
    [super dealloc];
}


-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    
    if (self) {
        [self creatBell];
    }
    return self;
}

- (void)creatBell{
  
    self.myImageBell = [[LzwBaseImageView alloc]initWithFrame:CGRectMake(10 * WIDTH, 10 * WIDTH, 355 * WIDTH, 125 * WIDTH)];
    
    self.myImageBell1 = [[LzwBaseImageView alloc]initWithFrame:CGRectMake(5 * WIDTH, 5 * WIDTH, 20 * WIDTH, 20 * WIDTH)];
    self.myImageBell1.image = [UIImage imageNamed:@"xin.png"];
    [self.myImageBell addSubview:self.myImageBell1];
    
}

- (void)setModleBell:(LzwBellModle *)modleBell{
    
    if (_modleBell != modleBell) {
        [_modleBell release];
        _modleBell = [modleBell retain];
    }
    
    NSURL *url = [NSURL URLWithString:self.modleBell.photo];
    
    [self.myImageBell sd_setImageWithURL:url placeholderImage:nil];
    
    [self.contentView addSubview:self.myImageBell];
    
}


@end
